package com.ruoyi.system.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.GuiProjectMapper;
import com.ruoyi.system.domain.GuiProject;
import com.ruoyi.system.service.IGuiProjectService;

/**
 * 产品
Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-01-06
 */
@Service
public class GuiProjectServiceImpl implements IGuiProjectService 
{
    @Autowired
    private GuiProjectMapper guiProjectMapper;

    /**
     * 查询产品

     * 
     * @param id 产品
主键
     * @return 产品

     */
    @Override
    public GuiProject selectGuiProjectById(Long id)
    {
        return guiProjectMapper.selectGuiProjectById(id);
    }

    /**
     * 查询产品
列表
     * 
     * @param guiProject 产品

     * @return 产品

     */
    @Override
    public List<GuiProject> selectGuiProjectList(GuiProject guiProject)
    {
        return guiProjectMapper.selectGuiProjectList(guiProject);
    }

    /**
     * 新增产品

     * 
     * @param guiProject 产品

     * @return 结果
     */
    @Override
    public int insertGuiProject(GuiProject guiProject)
    {
        guiProject.setCreateTime(DateUtils.getNowDate());
        return guiProjectMapper.insertGuiProject(guiProject);
    }

    /**
     * 修改产品

     * 
     * @param guiProject 产品

     * @return 结果
     */
    @Override
    public int updateGuiProject(GuiProject guiProject)
    {
        guiProject.setUpdateTime(DateUtils.getNowDate());
        return guiProjectMapper.updateGuiProject(guiProject);
    }

    /**
     * 批量删除产品

     * 
     * @param ids 需要删除的产品
主键
     * @return 结果
     */
    @Override
    public int deleteGuiProjectByIds(Long[] ids)
    {
        return guiProjectMapper.deleteGuiProjectByIds(ids);
    }

    /**
     * 删除产品
信息
     * 
     * @param id 产品
主键
     * @return 结果
     */
    @Override
    public int deleteGuiProjectById(Long id)
    {
        return guiProjectMapper.deleteGuiProjectById(id);
    }
}
